package com.test2;

public class Student {
    private String name;
    private int age;
public Student(){

}
    public void setName(String name){
        this.name = name;
    }

    public String getName(){
        return name;
    }

    public void setAge(int age){
        this.age = age;
    }

    public int getAge(){
        return age;//=return this.age
    }

    public void show(){
        System.out.println(name + "..." + age);
    }
}
 class TestStudent {
    public static void main(String[] args) {
        Student stu = new Student();
        stu.setName("张三");
        stu.setAge(23);


        stu.show();  // 仅仅是对数据做展示
    }
}

